import request from '@/utils/request'

// 查询供应商
export function querySupplierList(params) {
    return request({
        url: '/admin/supplier/manage/list',
        method: 'get',
        params,
    })
}

// 新增供应商
export function addSupplier(data) {
    return request({
        url: '/admin/supplier/manage/add',
        method: 'post',
        data,
    })
}

//编辑供应商
export function editSupplier(data) {
    return request({
        url: '/admin/supplier/manage/update',
        method: 'post',
        data,
    })
}

//删除供应商
export function deleteSupplier(id) {
    return request({
        url: `/admin/supplier/manage/${id}`,
        method: 'delete',
    })
}


//修改供应商状态
export function editSupplierStatus(data) {
    return request({
        url: `/admin/supplier/manage/state`,
        method: 'post',
        data,
    })
}